package com.frossini.proyectologin;


import com.frossini.proyectologin.adapter.TareasAdapter;
import com.nostra13.universalimageloader.core.ImageLoader;
import com.nostra13.universalimageloader.core.ImageLoaderConfiguration;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.TextView;
import android.os.Build;

public class PrincipalActivity extends Activity 
{
	  @Override
	    protected void onCreate(Bundle savedInstanceState) 
	  {
	        super.onCreate(savedInstanceState);
	        setContentView(R.layout.activity_principal);
	        
	        initILConfig();
	        
			Button pant_tareas = (Button) findViewById(R.id.btnmod_tareas);
			pant_tareas.setOnClickListener(new OnClickListener() 
			{
				@Override
				public void onClick(View v)
				{
					Intent llamarnueva = new Intent(PrincipalActivity.this,MainActivityTareas.class); // llama a la activity de tarea
					startActivityForResult(llamarnueva, 0); 
				}
			});
			Button pant_clientes = (Button) findViewById(R.id.btnmod_clientes);
			pant_clientes.setOnClickListener(new OnClickListener() 
			{
				@Override
				public void onClick(View v)
				{
					Intent llamarnueva = new Intent(PrincipalActivity.this,MainActivityClientes.class); // llama a la activity de tarea
					startActivityForResult(llamarnueva, 0); 
				}
			});
			
	  }

	private void initILConfig() 
	{
		// TODO Auto-generated method stub
		  // Create global configuration and initialize ImageLoader with this config
        ImageLoaderConfiguration config = new ImageLoaderConfiguration.Builder(this)
            .build();
        ImageLoader.getInstance().init(config);
	}
}
	


